package me.sample.web.service;

import me.sample.web.mapper.UserMapper;
import me.sample.web.model.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserService {

    @Autowired
    private UserMapper userMapper;


    public List<User> getUserList(){
        return  userMapper.selectAll();
    }


    public void addUser(User user){
        userMapper.insert(user);
    }
}
